import { createRouter, createWebHistory } from 'vue-router'
import layout from '@/layout/index.vue'
import home from '@/home/index.vue'
const router = createRouter({
  history: createWebHistory(),
  routes: [
    {
      path: '/',
      name: 'layout',
      component: layout,
      children: [
        {
          path: '',
          name: 'home',
          component: home
        }
      ]
    }
    // {
    //   path: '/login',
    //   name: 'login',
    //   component: login
    // }
  ],
  scrollBehavior() {
    return { left: 0, top: 0, behavior: 'smooth' }
  }
})

export default router
